// function getSum(num1: number, num2: number): number {
//   return num1 + num2
// }

// const sum = getSum(2, 3)

// console.log(sum)

function sayHello(): void {
  console.log('哈喽')
}

function errorFunc(): never {
  throw new Error('嘿嘿')
}

function forNever(): never {
  while (true) {}
}

function add({ a, b }: { a: number; b: number }): number {
  return a + b
}

console.log(add({ a: 1, b: 2 }))

const getNum: ({ one }: { one: number }) => number = ({ one }) => {
  return one
}

console.log(getNum({ one: 1111 }))
